package com.freemalll.merchant.domain.vo.merchantParameters;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.freemalll.merchant.domain.dto.merchantParameters.MerParamsDetailDTO;
import com.freemalll.merchant.domain.dto.merchantParameters.ParamsLogDTO;
import com.freemalll.merchant.utils.CustomLocalDateTimeSerializer;
import com.freemalll.merchant.utils.CustomLocalTimeDeserializer;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 *参数详情vo
 */
@Data
@Tag(name = "参数详情")
public class MerParamsDetailVO {

    @Schema(description = "主键id")
    private String id;

    /**
     * 模板编码
     */
    @Schema(description = "模板编码")
    private String paramCode;

    /**
     * 参数名称
     */
    @Schema(description = "参数名称")
    private String paramName;

    @Schema(description = "参数模板说明")
    private String remark;

    /**
     * 应用板块
     */
    @Schema(description = "应用板块id,多个板块使用,分割")
    private String applyLocation;

    /**
     * 应用板块
     */
    @Schema(description = "更新时间")
    @JsonSerialize(using = CustomLocalDateTimeSerializer.class)
    @JsonDeserialize(using = CustomLocalTimeDeserializer.class)
    private LocalDateTime updateTime;


    @Schema(description = "参数详情")
    private List<MerParamsDetailDTO> paramsDetailList = new ArrayList<>();

    @Schema(description = "参数日志")
    List<ParamsLogDTO> paramsLogList = new ArrayList<>();

    @Schema(description = "应用板块")
    private List<MerParamsDetailDTO> applyLocationList = new ArrayList<>();
}
